<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title></title>
    <link rel="stylesheet" type="text/css" href="../../css/api.css" />
    <style>
        [v-cloak] {
            display: none;
        }

        html,
        body {
            height: 100%;
            width: 100%;
            background-color: #FEFEFE;
            padding: 0;
            margin: 0;
        }

        #app{
            padding: 75px 0;
            display: flex;
            flex-direction: column;
            align-items: center;
            text-align: center;
        }

        /*导航栏样式*/
        #header {
            position: fixed;
            height: 50px;
            z-index: 10;
            top: 25px;
            left: 0;
            right: 0;
            padding-left: 10px;
            padding-right: 10px;
            background-color: #FEFEFE;
        }

        #header img {
            height: 20px;
            width: 20px;
            padding: 15px;
            float: left;
        }

        #header img:active{
            background-color: #ddd;
            border-radius: 50%;
        }

        #header p {
            right: 56px;
            left: 56px;
            display: inline-block;
            overflow: hidden;
            width: auto;
            margin: 0;
            padding: 0;
            text-overflow: ellipsis;
            line-height: 50px;
            position: absolute;
            text-align: center;
            white-space: nowrap;
            color: #515151;
            font-size: 20px;
        }

        #logo {
            height: 100px;
            width: auto;
        }

        #usernumber {
            display: block;
            height: 44px;
            width: 260px;
            background-color: #FEFEFE;
            margin-bottom: 10px;
            padding: 4px 16px 4px 50px;
            outline: none;
            border-bottom: 1px solid #ddd;
            color: #777;
            font-size: 18px;
        }
        #usernumber:hover{
            border-bottom: 1px solid #1296db;
        }

        #usernumber-icon {
            position: absolute;
            height: 30px;
            width: 30px;
            left: 10px;
            top: 10px;
        }

        #password {
            display: block;
            height: 44px;
            width: 260px;
            background-color: #FEFEFE;
            margin-bottom: 10px;
            padding: 4px 16px 4px 50px;
            outline: none;
            border-bottom: 1px solid #ddd;
            color: #777;
            font-size: 18px;
        }
        #password:hover{
            border-bottom: 1px solid #1296db;
        }

        #password-icon {
            position: absolute;
            height: 30px;
            width: 30px;
            left: 10px;
            top: 10px;
        }

        #qq {
            display: block;
            height: 44px;
            width: 260px;
            background-color: #FEFEFE;
            margin-bottom: 10px;
            padding: 4px 16px 4px 50px;
            outline: none;
            border-bottom: 1px solid #ddd;
            color: #777;
            font-size: 18px;
        }
        #qq:hover{
            border-bottom: 1px solid #1296db;
        }

        #qq-icon {
            position: absolute;
            height: 30px;
            width: 30px;
            left: 10px;
            top: 10px;
        }

        .login {
            height: 50px;
            width: 330px;
            line-height: 50px;
            background: #1296DB;
            color: #fff;
            border-radius: 10px;
            margin-bottom: 10px;
            font-size: 18px;
            text-align: center;
        }
        .login:active{
            opacity: 0.7;
        }

        .go-register {
            display: flex;
            align-items: center;
            justify-content: center;
            color: #009688;
            font-size: 18px;
            text-align: center;
        }
        .go-register div{
          display: flex;
          align-items: center;
        }
        .go-register img{
          height: 16px;
          width: 16px;
        }
        .go-register:active{
            opacity: 0.7;
        }

        .register {
            height: 50px;
            width: 330px;
            line-height: 50px;
            background: #1296DB;
            color: #fff;
            border-radius: 10px;
            margin-bottom: 10px;
            font-size: 18px;
            text-align: center;
        }
        .register:active{
            opacity: 0.7;
        }

        .go-login {
            display: flex;
            align-items: center;
            justify-content: center;
            color: #009688;
            font-size: 18px;
            text-align: center;
        }
        .go-login div{
          display: flex;
          align-items: center;
        }
        .go-login img{
          height: 16px;
          width: 16px;
        }
        .go-login:active{
            opacity: 0.7;
        }

        .disabled {
            pointer-events: none;
            background: #A9A9A9;
        }

    </style>
</head>

<body>

    <div id="app" v-cloak>

        <!-- 我是占位状态栏高度的 -->
        <div class="statusBarPlaceholder" style="height:25px;width:100%;background-color:#FEFEFE;position:fixed;top:0;"></div>
        <!-- 我是导航栏 -->
        <header id="header">
            <img class="close" src="../../image/back.png" @click="goBack">
            <p class="title" v-show="currentLoginState">登录</p>
            <p class="title" v-show="!currentLoginState">注册</p>
        </header>

        <div class="content-container" v-if="currentLoginState">
            <img id="logo" src="../../image/clicli-logo.png" alt="">
            <div style="position:relative;">
                <img id="usernumber-icon" src="../../image/usernumber.png" alt="">
                <input id="usernumber" type="text" v-model="name" @input="listenChange" @porpertychange="listenChange" placeholder="用户名">
            </div>
            <div style="position:relative;">
                <img id="password-icon" src="../../image/password.png" alt="">
                <input id="password" type="password" v-model="pwd" @input="listenChange" @porpertychange="listenChange" placeholder="密码">
            </div>
            <div class="login disabled" @click="login">登录</div>
            <div class="go-register">
              <div @click="goRegister">
                <span>注册</span><img src="../../image/right.png" />
              </div>
            </div>
        </div>

        <div class="content-container" v-if="!currentLoginState">
            <img id="logo" src="../../image/clicli-logo.png" alt="">
            <div style="position:relative;">
                <img id="usernumber-icon" src="../../image/usernumber.png" alt="">
                <input id="usernumber" type="text" v-model="Rname" @input="RlistenChange" @porpertychange="RlistenChange" placeholder="用户名">
            </div>
            <div style="position:relative;">
                <img id="password-icon" src="../../image/password.png" alt="">
                <input id="password" type="text" v-model="Rpwd" @input="RlistenChange" @porpertychange="RlistenChange" placeholder="密码">
            </div>
            <div style="position:relative;">
                <img id="qq-icon" src="../../image/search.png" alt="">
                <input id="qq" type="text" v-model="Rqq" @input="RlistenChange" @porpertychange="RlistenChange" placeholder="QQ号">
            </div>
            <div class="register disabled" @click="register">注册</div>
            <div class="go-login">
              <div @click="goLogin">
                <span>登录</span><img src="../../image/right.png" />
              </div>
            </div>
        </div>

    </div>

    <script src="../../script/vendors/api.js"></script>
    <script src="../../script/vendors/vue.min.js"></script>
    <script src="../../script/vendors/axios.min.js"></script>
    <script src="../../script/dist/login.js"></script>
</body>

</html>
